﻿<!DOCTYPE html>
<html>

<head>
    <meta charset="utf-8" />
    <meta name="viewport" content="width=device-width, initial-scale=1" />
    <title>
        可收缩的内容集合  
    </title>

         
    <link href="../../Content/jquery.mobile-1.2.0.min.css" rel="stylesheet" type="text/css" />
        
    <script src="../../Scripts/jquery-1.8.2.min.js" type="text/javascript"></script>
    <script src="../../Scripts/jquery.mobile-1.2.0.min.js" type="text/javascript"></script>        
</head>


<body>


<!-- data-role = page  用于定义  一个页面.  -->
<div data-role="page">


    <!--  data-role = header  用于定义一个 顶部标题.  -->
    <div data-role="header">
	    <h1>可收缩的内容  </h1>
        <a href="/html5/home.html" data-icon="home" data-iconpos="notext" data-direction="reverse">Home</a>
    </div>  <!-- /header -->



    <!--  data-role = content  用于定义一个 中间内容区域.  -->
    <div data-role="content">
        

        <h2> 默认 </h2>

	<pre><code>		
<strong>&lt;div data-role="collapsible-set"&gt;</strong>

	&lt;div data-role=&quot;collapsible&quot; <strong>data-collapsed=&quot;false&quot;</strong>&gt;
	&lt;h3&gt;Section 1&lt;/h3&gt;
	&lt;p&gt;I&#x27;m the collapsible set content for section 1.&lt;/p&gt;
	&lt;/div&gt;
	
	&lt;div data-role=&quot;collapsible&quot;&gt;
	&lt;h3&gt;Section 2&lt;/h3&gt;
	&lt;p&gt;I&#x27;m the collapsible set content for section 2.&lt;/p&gt;
	&lt;/div&gt;
	
<strong>&lt;/div&gt;</strong>
	</code></pre>	

		<p> 例子.</p>
		
		<div data-role="collapsible-set">
			<div data-role="collapsible" data-collapsed="false">
				<h3>标题 1</h3>
				<p> 内容1.  因为设置了 data-collapsed="false"， 因此默认展开    </p>
			</div>
			<div data-role="collapsible">
				<h3>标题 2</h3>
				<p> 内容2.</p>
			</div>
			<div data-role="collapsible">
				<h3>标题 3</h3>
				<p> 内容3.</p>
			</div>
			<div data-role="collapsible">
				<h3>标题 4</h3>
				<p> 内容4.</p>
			</div>
			<div data-role="collapsible">
				<h3>标题 5</h3>
				<p> 内容5.</p>
			</div>
		</div>




        <h2> 宽度满屏 </h2>

        <p>
        使用 <code>	  <strong> data-inset=&quot;false&quot; </strong>  </code> 处理.
        </p>

        
		<div data-role="collapsible-set" data-inset="false">
			<div data-role="collapsible">
				<h3>标题 1</h3>
				<p>内容1.</p>
			</div>
			<div data-role="collapsible">
				<h3>标题 2</h3>
				<p>内容2.</p>
			</div>
			<div data-role="collapsible">
				<h3>标题 3</h3>
				<p>内容3.</p>
			</div>
		</div>	




        <h2> Mini 版本 </h2>
        <p>
        使用 <code>	  <strong>data-mini=&quot;true&quot;</strong>  </code> 处理.
        </p>


		<div data-role="collapsible-set" data-theme="c" data-mini="true">
			<div data-role="collapsible">
				<h3>标题 1</h3>
				<p>内容1.</p>
			</div>
			<div data-role="collapsible">
				<h3>标题 2</h3>
				<p>内容2.</p>
			</div>
			<div data-role="collapsible">
				<h3>标题 3</h3>
				<p>内容3.</p>
			</div>
		</div>




        <h2> 自定义图标 </h2>

        <code>	
        <strong>data-collapsed-icon="arrow-r" data-expanded-icon="arrow-d"</strong>
        </code>

		<div data-role="collapsible-set" data-theme="c" data-collapsed-icon="arrow-r" data-expanded-icon="arrow-d">
			<div data-role="collapsible">
				<h3>标题 1</h3>
				<p>内容1.</p>
			</div>
			<div data-role="collapsible">
				<h3>标题 2</h3>
				<p>内容2.</p>
			</div>
			<div data-role="collapsible">
				<h3>标题 3</h3>
				<p>内容3.</p>
			</div>
		</div>







        <h2> 图标位置 </h2>

		<div data-role="collapsible-set" data-theme="c" data-iconpos="right">
			<div data-role="collapsible">
				<h3>Section 1</h3>
				<p>Inherits icon positioning from <code>data-iconpos="right"</code> attribute on parent.</p>
			</div>
			<div data-role="collapsible" data-iconpos="left">
				<h3>Section 2</h3>
				<p>data-iconpos="left"</p>
			</div>
			<div data-role="collapsible" data-iconpos="bottom">
				<h3>Section 3</h3>
				<p>data-iconpos="bottom"</p>
			</div>
			<div data-role="collapsible" data-iconpos="top">
				<h3>Section 4</h3>
				<p>data-iconpos="top"</p>
			</div>
		</div>


        
        <h2> 样式主题 </h2>

<pre><code>		
&lt;div data-role=&quot;collapsible-set&quot; <strong>data-theme=&quot;c&quot; data-content-theme=&quot;d&quot;</strong>&gt;
</code></pre>	


		<div data-role="collapsible-set" data-theme="c" data-content-theme="d">
			<div data-role="collapsible">
				<h3>Section 1</h3>
				<p>Collapsible content</p>
			</div>
			<div data-role="collapsible">
				<h3>Section 2</h3>
				<p>Collapsible content</p>

			</div>
			<div data-role="collapsible">
				<h3>Section 3</h3>
				<p>Collapsible content</p>
			</div>
		</div>



		<div data-role="collapsible-set" data-content-theme="c">
			<div data-role="collapsible" data-theme="b" data-content-theme="b">
				<h3>Section header, swatch B</h3>
				<p>Collapsible content, swatch "b"</p>
			</div>
			<div data-role="collapsible" data-theme="a" data-content-theme="a">
				<h3>Section header, swatch A</h3>
				<p>Collapsible content, swatch "a"</p>
			</div>
			<div data-role="collapsible" data-theme="e" data-content-theme="d">
				<h3>Section header, swatch E</h3>
				<p>Collapsible content, swatch "d"</p>
			</div>
		</div>


    </div> <!-- /content -->





    <!--  data-role = footer  用于定义一个 底部标题.  -->
	<div data-role="footer" data-id="foo1" data-position="fixed">
        <h3>
            Footer
        </h3>
	</div><!-- /footer -->

</div><!-- /page -->



</body>
</html>
